import axios from "../../util/request";

//pickup头部请求
export const pickupheader = () => {
    return axios.get(`/adminapi/merchant/store/get_header`);
};

//pickup列表请求
export const pickuplist = (val) => {
    return axios.get(`/adminapi/merchant/store?page=${val.page}&limit=${val.limit}&type=${val.type}&keywords=${val.key}`);
};

//switch状态切换
export const pickupstatus = (val) => {
    return axios.put(`/adminapi/merchant/store/set_show/${val.ids}/${val.status}`);
};

//提货点删除
export const pickupdel = (val) => {
    return axios.delete(`/adminapi/merchant/store/del/${val}`);
};

//提货点添加
export const pickupadd = (val) => {
    return axios.post(`/adminapi/merchant/store/0`,val);
};

//提货编辑/adminapi/merchant/store/7
export const pickupedit = (val) => {
    return axios.post(`/adminapi/merchant/store/${val.id}`,val);
};